<!DOCTYPE html>
<html lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>create_variation_model [HALCON算子参考手册]</title>
<style type="text/css">
      body {
    color: #000000;
    background-color: #ffffff;
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
}

.body_main {
    margin-left: 35px;
    margin-right: 35px;
}

@media screen and (min-width:992px) {

    .body_main {
        margin-left: 10%;
        margin-right: 10%;
    }

    table.toctable {
        width: 80%
    }
}

@media screen and (min-width:1400px) {

    .body_main {
        margin-left: 15%;
        margin-right: 15%;
    }

    table.toctable {
        width: 70%
    }
}

body>div ul ul {
    margin-left: inherit;
}

a:link {
    color: #0044cc;
}

a:link,
a:visited {
    text-decoration: none;
}

a:link:hover,
a:visited:hover {
    text-decoration: underline;
}

th {
    text-align: left;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    text-rendering: optimizeLegibility;
    color: #666666;
}

code {
    font-family: monospace,monospace;
}

h1 a.halconoperator {
    font-family: Arial, Helvetica, sans-serif;
    color: #666666;
}

h2 a.halconoperator {
    font-family: Arial, Helvetica, sans-serif;
    color: #666666;
}

hr {
    border: 0;
    border-top: solid 1px #f28d26;
}

.pre {
    display: block;
    padding-bottom: 1ex;
    font-family: monospace;
    white-space: pre;
}

pre {
    font-family: monospace, monospace;
    padding: 1ex;
    white-space: pre-wrap;
}

.toc {
    font-size: 80%;
    border-top: 1px dashed #f28d26;
    border-bottom: 1px dashed #f28d26;
    padding-top: 5px;
    padding-bottom: 5px;
}

.inv {
    margin: 0;
    border: 0;
    padding: 0;
}

.banner {
    color: #666666;
    padding-left: 1em;
}

.logo {
    background-color: white;
}

.keyboard {
    font-size: 80%;
    padding-left: 3px;
    padding-right: 3px;
    border-radius: 5px;
    border-width: 1px;
    border-style: solid;
    border-color: #f28d26;
    background-color: #f3f3f3;
}

.warning {
    margin-top: 2ex;
    margin-bottom: 1ex;
    padding: 10px;
    text-align: center;
    border: 1px solid;
    color: #bb0000;
    background-color: #fff7f7
}

.imprint {
    margin-top: 1ex;
    font-size: 80%;
    color: #666666;
}

.imprinthead {
    font-weight: bolder;
    color: #666666;
}

.indexlink {
    text-align: right;
    padding-bottom: 5px;
}

.postscript {
    margin-top: 2ex;
    font-size: 80%;
    color: #666666
}

.evenrow {
    background-color: #e7e7ef;
    vertical-align: top;
}

.oddrow {
    background-color: #f7f7ff;
    vertical-align: top;
}

.headrow {
    background-color: #97979f;
    color: #ffffff;
    vertical-align: top;
}

.logorow {
    vertical-align: top;
}

.error {
    color: red;
}

.var {
    font-style: italic
}

.halconoperator {
    font-family: monospace, monospace;
}

span.operator {
    font-family: monospace, monospace;
}

span.procedure {
    font-family: monospace, monospace;
}

span.operation {
    font-family: monospace, monospace;
}

span.feature {
    font-family: Arial, Helvetica, Homerton, sans-serif;
}

ul {
    padding-left: 1.2em;
}

li.dot {
    list-style-type: square;
    color: #f28d26;
}

.breadcrumb {
    font-size: 80%;
    color: white;
    background-color: #062d64;
    margin-bottom: 20px;
    padding-left: 35px;
    padding-right: 35px;
    padding-bottom: 15px;
}

.webbar {
    font-size: 80%;
    background-color: #dddddd;
    margin-top: 0px;
    margin-left: -35px;
    margin-right: -35px;
    margin-bottom: 0px;
    padding-top: 5px;
    padding-left: 35px;
    padding-right: 35px;
    padding-bottom: 5px;
}

.footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    border-top: 1px dashed #f28d26;
    font-size: 80%;
    color: #666666;
    padding-bottom: 8px;
}

.footer .socialmedia a {
    padding-left: 7px;
}

.socialmedia {
    padding-top: 10px;
}

.copyright {
    margin-top: 19px;
}

.breadcrumb a {
    color: #ffffff;
    border-bottom: 1px solid white;
}

.breadcrumb a:link:hover,
.breadcrumb a:visited:hover {
    text-decoration: none;
    border-bottom: none;
}

.heading {
    margin-top: 1ex;
    font-size: 110%;
    font-weight: bold;
    color: #666666;
}

.text {
    color: black;
}

.example {
    font-size: 80%;
    background-color: #f3f3f3;
    border: 1px dashed #666666;
    padding: 10px;
}

.displaymath {
    display: block;
    text-align: center;
    margin-top: 1ex;
    margin-bottom: 1ex;
}

.title {
    float: left;
    padding-top: 3px;
    padding-bottom: 3px;
}

.signnote {
    font-family: Arial, Helvetica, Homerton, sans-serif;
    font-size: 80%;
    color: #666666;
    font-weight: lighter;
    font-style: italic
}

.par {
    margin-bottom: 1.5em;
}

.parhead {
    text-align: right;
}

.parname {
    float: left;
}

.pardesc {
    font-size: 85%;
    margin-top: 0.5em;
    margin-bottom: 0.5em;
    margin-left: 2em;
}

.parcat {
    color: #666;
    font-weight: bold;
}

*[data-if=cpp],
*[data-if=c],
*[data-if=dotnet],
*[data-if=com],
*[data-if=python] {
    display: none;
}

.tabbar {
    text-align: right;
    border-bottom: 1px solid #f28d26;
    margin-bottom: 0.5em;
}

ul.tabs {
    padding-top: 3px;
    padding-bottom: 3px;
    margin-top: 10px;
    margin-bottom: 0;
    font-size: 80%
}

ul.tabs li {
    padding-top: 3px;
    padding-bottom: 3px;
    display: inline;
    overflow: hidden;
    list-style-type: none;
    margin: 0;
    margin-left: 8px;
    border-top: 1px solid #666;
    border-left: 1px solid #666;
    border-right: 1px solid #666;
}

ul.tabs li.active {
    border-left: 1px solid #f28d26;
    border-right: 1px solid #f28d26;
    border-top: 1px solid #f28d26;
    border-bottom: 1px solid #fff;
}

ul.tabs li.inactive {
    background-color: #eee;
}

ul.tabs li a {
    padding-left: 5px;
    padding-right: 5px;
    color: #666;
}

ul.tabs li a:link:hover {
    text-decoration: none;
}

ul.tabs li.inactive a {
    color: #666;
}

ul.tabs li.active a {
    color: black;
}

dl.generic dd {
    margin-bottom: 1em;
}

.pari {
    color: olive;
}

.paro {
    color: maroon;
}

.comment {
    font-size: 80%;
    color: green;
    white-space: nowrap;
}

table.grid {
    border-collapse: collapse;
}

table.grid td {
    padding: 5px;
    border: 1px solid;
}

table.layout {
    border: 0px;
}

table.layout td {
    padding: 5px;
}

table.table {
    border-collapse: collapse;
}

table.table td {
    padding: 5px;
    border-left: 0px;
    border-right: 0px;
}

table.table tr:last-child {
    border-bottom: 1px solid;
}

table.table th {
    padding: 5px;
    border-top: 1px solid;
    border-bottom: 1px solid;
    border-left: 0px;
    border-right: 0px;
}

.details_summary {
    cursor: pointer;
}

table.toctable {
    width: 100%;
}

table.toctable col:first-child {
    width: 20%;
}

table.toctable col:nth-last-child(2) {
    width: 8%;
}

table.altcolored tr:nth-child(even) {
    background-color: #f3f3f3;
}

    </style>
<!--OP_REF_STYLE_END-->
<script>
    <!--
var active_lang='hdevelop';function switchVisibility(obj,active_lang,new_lang)
{var display_style='inline';
for(var i=0;i<obj.length;i++)
{if(obj.item(i).getAttribute('data-if')==new_lang)
{obj.item(i).style.display=display_style;}
if(obj.item(i).getAttribute('data-if')==active_lang)
{obj.item(i).style.display='none';}}
return;}
function toggleLanguage(new_lang,initial)
{if(active_lang!=new_lang)
{var lis=document.getElementsByTagName('li');for(var i=0;i<lis.length;i++)
{if(lis.item(i).id=='syn-'+new_lang)
{lis.item(i).className='active';}
else
{lis.item(i).className='inactive';}}
var divs=document.getElementsByTagName('div');var spans=document.getElementsByTagName('span');switchVisibility(divs,active_lang,new_lang);switchVisibility(spans,active_lang,new_lang);if(!initial)
{setCookie("halcon_reference_language",new_lang,null,null);}
active_lang=new_lang;}
return;}
function setCookie(name,value,domain,exp_offset,path,secure)
{localStorage.setItem(name,value);}
function getCookie(name)
{return localStorage.getItem(name);}
function initialize()
{var qs=location.href.split('?')[1];var qs_lang_raw=location.href.split('interface=')[1];var qs_lang;if(qs_lang_raw)
{qs_lang=qs_lang_raw.split('#')[0];}
var cookie_lang=getCookie("halcon_reference_language");var new_lang;if((qs_lang=="hdevelop")||(qs_lang=="dotnet")||(qs_lang=="python")||(qs_lang=="cpp")||(qs_lang=="c"))
{new_lang=qs_lang;setCookie("halcon_reference_language",new_lang,null,null);}
else if((cookie_lang=="hdevelop")||(cookie_lang=="dotnet")||(cookie_lang=="python")||(cookie_lang=="cpp")||(cookie_lang=="c"))
{new_lang=cookie_lang;}
else
{new_lang="hdevelop";}
toggleLanguage(new_lang,1);return;}
-->

  </script>
</head>
<body onload="initialize();">
<div class="breadcrumb">
<br class="inv"><a href="index.html">目录</a> / <a href="toc_inspection.html">Inspection</a> / <a href="toc_inspection_variationmodel.html">Variation Model</a><br class="inv">
</div>
<div class="body_main">
<div class="tabbar"><ul class="tabs">
<li id="syn-hdevelop" class="active"><a href="javascript:void(0);" onclick="toggleLanguage('hdevelop')" onfocus="blur()">HDevelop</a></li>
<li id="syn-dotnet" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('dotnet')" onfocus="blur()">.NET</a></li>
<li id="syn-python" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('python')" onfocus="blur()">Python</a></li>
<li id="syn-cpp" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('cpp')" onfocus="blur()">C++</a></li>
<li id="syn-c" class="inactive"><a href="javascript:void(0);" onclick="toggleLanguage('c')" onfocus="blur()">C</a></li>
</ul></div>
<div class="indexlink">
<a href="index_classes.html"><span data-if="dotnet" style="display:none;">类别</span><span data-if="cpp" style="display:none;">类别</span></a><span data-if="dotnet" style="display:none;"> | </span><span data-if="cpp" style="display:none;"> | </span><a href="index_by_name.html">算子列表</a>
</div>
<!--OP_REF_HEADER_END-->
<h1 id="sec_name">
<span data-if="hdevelop" style="display:inline;">create_variation_model</span><span data-if="c" style="display:none;">T_create_variation_model</span><span data-if="cpp" style="display:none;">CreateVariationModel</span><span data-if="dotnet" style="display:none;">CreateVariationModel</span><span data-if="python" style="display:none;">create_variation_model</span> (算子名称)</h1>
<h2>名称</h2>
<p><code><span data-if="hdevelop" style="display:inline;">create_variation_model</span><span data-if="c" style="display:none;">T_create_variation_model</span><span data-if="cpp" style="display:none;">CreateVariationModel</span><span data-if="dotnet" style="display:none;">CreateVariationModel</span><span data-if="python" style="display:none;">create_variation_model</span></code> — Create a variation model for image comparison.</p>
<h2 id="sec_synopsis">参数签名</h2>
<div data-if="hdevelop" style="display:inline;">
<p>
<code><b>create_variation_model</b>( :  : <a href="#Width"><i>Width</i></a>, <a href="#Height"><i>Height</i></a>, <a href="#Type"><i>Type</i></a>, <a href="#Mode"><i>Mode</i></a> : <a href="#ModelID"><i>ModelID</i></a>)</code></p>
</div>
<div data-if="c" style="display:none;">
<p>
<code>Herror <b>T_create_variation_model</b>(const Htuple <a href="#Width"><i>Width</i></a>, const Htuple <a href="#Height"><i>Height</i></a>, const Htuple <a href="#Type"><i>Type</i></a>, const Htuple <a href="#Mode"><i>Mode</i></a>, Htuple* <a href="#ModelID"><i>ModelID</i></a>)</code></p>
</div>
<div data-if="cpp" style="display:none;">
<p>
<code>void <b>CreateVariationModel</b>(const HTuple&amp; <a href="#Width"><i>Width</i></a>, const HTuple&amp; <a href="#Height"><i>Height</i></a>, const HTuple&amp; <a href="#Type"><i>Type</i></a>, const HTuple&amp; <a href="#Mode"><i>Mode</i></a>, HTuple* <a href="#ModelID"><i>ModelID</i></a>)</code></p>
<p>
<code>void <a href="HVariationModel.html">HVariationModel</a>::<b>HVariationModel</b>(Hlong <a href="#Width"><i>Width</i></a>, Hlong <a href="#Height"><i>Height</i></a>, const HString&amp; <a href="#Type"><i>Type</i></a>, const HString&amp; <a href="#Mode"><i>Mode</i></a>)</code></p>
<p>
<code>void <a href="HVariationModel.html">HVariationModel</a>::<b>HVariationModel</b>(Hlong <a href="#Width"><i>Width</i></a>, Hlong <a href="#Height"><i>Height</i></a>, const char* <a href="#Type"><i>Type</i></a>, const char* <a href="#Mode"><i>Mode</i></a>)</code></p>
<p>
<code>void <a href="HVariationModel.html">HVariationModel</a>::<b>HVariationModel</b>(Hlong <a href="#Width"><i>Width</i></a>, Hlong <a href="#Height"><i>Height</i></a>, const wchar_t* <a href="#Type"><i>Type</i></a>, const wchar_t* <a href="#Mode"><i>Mode</i></a>)  <span class="signnote">
            (
            Windows only)
          </span></code></p>
<p>
<code>void <a href="HVariationModel.html">HVariationModel</a>::<b>CreateVariationModel</b>(Hlong <a href="#Width"><i>Width</i></a>, Hlong <a href="#Height"><i>Height</i></a>, const HString&amp; <a href="#Type"><i>Type</i></a>, const HString&amp; <a href="#Mode"><i>Mode</i></a>)</code></p>
<p>
<code>void <a href="HVariationModel.html">HVariationModel</a>::<b>CreateVariationModel</b>(Hlong <a href="#Width"><i>Width</i></a>, Hlong <a href="#Height"><i>Height</i></a>, const char* <a href="#Type"><i>Type</i></a>, const char* <a href="#Mode"><i>Mode</i></a>)</code></p>
<p>
<code>void <a href="HVariationModel.html">HVariationModel</a>::<b>CreateVariationModel</b>(Hlong <a href="#Width"><i>Width</i></a>, Hlong <a href="#Height"><i>Height</i></a>, const wchar_t* <a href="#Type"><i>Type</i></a>, const wchar_t* <a href="#Mode"><i>Mode</i></a>)  <span class="signnote">
            (
            Windows only)
          </span></code></p>
</div>
<div data-if="com" style="display:none;"></div>
<div data-if="dotnet" style="display:none;">
<p>
<code>static void <a href="HOperatorSet.html">HOperatorSet</a>.<b>CreateVariationModel</b>(<a href="HTuple.html">HTuple</a> <a href="#Width"><i>width</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Height"><i>height</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Type"><i>type</i></a>, <a href="HTuple.html">HTuple</a> <a href="#Mode"><i>mode</i></a>, out <a href="HTuple.html">HTuple</a> <a href="#ModelID"><i>modelID</i></a>)</code></p>
<p>
<code>public <a href="HVariationModel.html">HVariationModel</a>(int <a href="#Width"><i>width</i></a>, int <a href="#Height"><i>height</i></a>, string <a href="#Type"><i>type</i></a>, string <a href="#Mode"><i>mode</i></a>)</code></p>
<p>
<code>void <a href="HVariationModel.html">HVariationModel</a>.<b>CreateVariationModel</b>(int <a href="#Width"><i>width</i></a>, int <a href="#Height"><i>height</i></a>, string <a href="#Type"><i>type</i></a>, string <a href="#Mode"><i>mode</i></a>)</code></p>
</div>
<div data-if="python" style="display:none;">
<p>
<code>def <b>create_variation_model</b>(<a href="#Width"><i>width</i></a>: int, <a href="#Height"><i>height</i></a>: int, <a href="#Type"><i>type</i></a>: str, <a href="#Mode"><i>mode</i></a>: str) -&gt; HHandle</code></p>
</div>
<h2 id="sec_description">描述</h2>
<p><code><span data-if="hdevelop" style="display:inline">create_variation_model</span><span data-if="c" style="display:none">create_variation_model</span><span data-if="cpp" style="display:none">CreateVariationModel</span><span data-if="com" style="display:none">CreateVariationModel</span><span data-if="dotnet" style="display:none">CreateVariationModel</span><span data-if="python" style="display:none">create_variation_model</span></code> creates a variation model that can be
used for image comparison.  The handle for the variation model is
returned in <a href="#ModelID"><i><code><span data-if="hdevelop" style="display:inline">ModelID</span><span data-if="c" style="display:none">ModelID</span><span data-if="cpp" style="display:none">ModelID</span><span data-if="com" style="display:none">ModelID</span><span data-if="dotnet" style="display:none">modelID</span><span data-if="python" style="display:none">model_id</span></code></i></a>.
</p>
<p>Typically, the variation model is used to discriminate correctly
manufactured objects (“good objects”) from incorrectly
manufactured objects (“bad objects”).  It is assumed that the
discrimination can be done solely based on the gray values of the
object.
</p>
<p>The variation model consists of an ideal image of the object to
which the images of the objects to be tested are compared later on
with <a href="compare_variation_model.html"><code><span data-if="hdevelop" style="display:inline">compare_variation_model</span><span data-if="c" style="display:none">compare_variation_model</span><span data-if="cpp" style="display:none">CompareVariationModel</span><span data-if="com" style="display:none">CompareVariationModel</span><span data-if="dotnet" style="display:none">CompareVariationModel</span><span data-if="python" style="display:none">compare_variation_model</span></code></a> or
<a href="compare_ext_variation_model.html"><code><span data-if="hdevelop" style="display:inline">compare_ext_variation_model</span><span data-if="c" style="display:none">compare_ext_variation_model</span><span data-if="cpp" style="display:none">CompareExtVariationModel</span><span data-if="com" style="display:none">CompareExtVariationModel</span><span data-if="dotnet" style="display:none">CompareExtVariationModel</span><span data-if="python" style="display:none">compare_ext_variation_model</span></code></a>, and an image that represents
the amount of gray value variation at every point of the object.
The size of the images with which the object model is trained and
with which the model is compared later on is passed in
<a href="#Width"><i><code><span data-if="hdevelop" style="display:inline">Width</span><span data-if="c" style="display:none">Width</span><span data-if="cpp" style="display:none">Width</span><span data-if="com" style="display:none">Width</span><span data-if="dotnet" style="display:none">width</span><span data-if="python" style="display:none">width</span></code></i></a> and <a href="#Height"><i><code><span data-if="hdevelop" style="display:inline">Height</span><span data-if="c" style="display:none">Height</span><span data-if="cpp" style="display:none">Height</span><span data-if="com" style="display:none">Height</span><span data-if="dotnet" style="display:none">height</span><span data-if="python" style="display:none">height</span></code></i></a>, respectively.  The image type of
the images used for training and comparison is passed in
<a href="#Type"><i><code><span data-if="hdevelop" style="display:inline">Type</span><span data-if="c" style="display:none">Type</span><span data-if="cpp" style="display:none">Type</span><span data-if="com" style="display:none">Type</span><span data-if="dotnet" style="display:none">type</span><span data-if="python" style="display:none">type</span></code></i></a>.
</p>
<p>The variation model is trained using multiple images of good
objects.  Therefore, it is essential that the training images show
the objects in the same position and rotation.  If this cannot be
guaranteed by external means, the pose of the object can, for
example, be determined by using matching (see
<a href="find_generic_shape_model.html"><code><span data-if="hdevelop" style="display:inline">find_generic_shape_model</span><span data-if="c" style="display:none">find_generic_shape_model</span><span data-if="cpp" style="display:none">FindGenericShapeModel</span><span data-if="com" style="display:none">FindGenericShapeModel</span><span data-if="dotnet" style="display:none">FindGenericShapeModel</span><span data-if="python" style="display:none">find_generic_shape_model</span></code></a>). The image can then be transformed to a
reference pose with <a href="affine_trans_image.html"><code><span data-if="hdevelop" style="display:inline">affine_trans_image</span><span data-if="c" style="display:none">affine_trans_image</span><span data-if="cpp" style="display:none">AffineTransImage</span><span data-if="com" style="display:none">AffineTransImage</span><span data-if="dotnet" style="display:none">AffineTransImage</span><span data-if="python" style="display:none">affine_trans_image</span></code></a>.
</p>
<p>The parameter <a href="#Mode"><i><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></i></a> is used to determine how the image of
the ideal object and the corresponding variation image are computed.
For <a href="#Mode"><i><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></i></a>=<i><span data-if="hdevelop" style="display:inline">'standard'</span><span data-if="c" style="display:none">"standard"</span><span data-if="cpp" style="display:none">"standard"</span><span data-if="com" style="display:none">"standard"</span><span data-if="dotnet" style="display:none">"standard"</span><span data-if="python" style="display:none">"standard"</span></i>, the ideal image of the object
is computed as the mean of all training images at the respective
image positions.  The corresponding variation image is computed as
the standard deviation of the training images at the respective
image positions.  This mode has the advantage that the variation
model can be trained iteratively, i.e., as soon as an image of a
good object becomes available, it can be trained with
<a href="train_variation_model.html"><code><span data-if="hdevelop" style="display:inline">train_variation_model</span><span data-if="c" style="display:none">train_variation_model</span><span data-if="cpp" style="display:none">TrainVariationModel</span><span data-if="com" style="display:none">TrainVariationModel</span><span data-if="dotnet" style="display:none">TrainVariationModel</span><span data-if="python" style="display:none">train_variation_model</span></code></a>.  The disadvantage of this mode is
that great care must be taken to ensure that only images of good
objects are trained, because the mean and standard deviation are not
robust against outliers, i.e., if an image of a bad object is
trained inadvertently, the accuracy of the ideal object image and
that of the variation image might be degraded.
</p>
<p>If it cannot be avoided that the variation model is trained with
some images of objects that can contain errors, <a href="#Mode"><i><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></i></a> can be
set to <i><span data-if="hdevelop" style="display:inline">'robust'</span><span data-if="c" style="display:none">"robust"</span><span data-if="cpp" style="display:none">"robust"</span><span data-if="com" style="display:none">"robust"</span><span data-if="dotnet" style="display:none">"robust"</span><span data-if="python" style="display:none">"robust"</span></i>.  In this mode, the image of the ideal
object is computed as the median of all training images at the
respective image positions.  The corresponding variation image is
computed as a suitably scaled median absolute deviation of the
training images and the median image at the respective image
positions.  This mode has the advantage that it is robust against
outliers.  It has the disadvantage that it cannot be trained
iteratively, i.e., all training images must be accumulated using
<a href="concat_obj.html"><code><span data-if="hdevelop" style="display:inline">concat_obj</span><span data-if="c" style="display:none">concat_obj</span><span data-if="cpp" style="display:none">ConcatObj</span><span data-if="com" style="display:none">ConcatObj</span><span data-if="dotnet" style="display:none">ConcatObj</span><span data-if="python" style="display:none">concat_obj</span></code></a> and be trained with <a href="train_variation_model.html"><code><span data-if="hdevelop" style="display:inline">train_variation_model</span><span data-if="c" style="display:none">train_variation_model</span><span data-if="cpp" style="display:none">TrainVariationModel</span><span data-if="com" style="display:none">TrainVariationModel</span><span data-if="dotnet" style="display:none">TrainVariationModel</span><span data-if="python" style="display:none">train_variation_model</span></code></a>
in a single call.
</p>
<p>In some cases, it is impossible to acquire multiple training images.
In this case, a useful variation image cannot be trained from the
single training image.  To solve this problem, variations of the
training image can be created synthetically, e.g., by shifting the
training image by <span title="1" style="vertical-align:-0.195552em" class="math"><!-- Created by MetaPost 1.902 on 2023.05.15:2033 --><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" width="1.399em" height="0.850062em" viewBox="0 0 22.384079 13.600998">
<!-- Original BoundingBox: -11.192047 -6.800491 11.192032 6.800507 -->
  <defs>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmr10_49">
      <path style="fill-rule: evenodd;" d="M294.000000 -640.000000C294.000000 -664.000000,294.000000 -666.000000,271.000000 -666.000000C209.000000 -602.000000,121.000000 -602.000000,89.000000 -602.000000L89.000000 -571.000000C109.000000 -571.000000,168.000000 -571.000000,220.000000 -597.000000L220.000000 -79.000000C220.000000 -43.000000,217.000000 -31.000000,127.000000 -31.000000L95.000000 -31.000000L95.000000 -0.000000L257.000000 -0.000000L130.000000 -3.000000L217.000000 -3.000000L257.000000 -3.000000L297.000000 -3.000000L384.000000 -3.000000L419.000000 -0.000000L419.000000 -31.000000L387.000000 -31.000000C297.000000 -31.000000,294.000000 -42.000000,294.000000 -79.000000"></path>
    </g>
    <g transform="scale(0.009963,0.009963)" id="GLYPHcmsy10_6">
      <path style="fill-rule: evenodd;" d="M409.000000 -313.000000L687.000000 -313.000000C704.000000 -313.000000,722.000000 -313.000000,722.000000 -333.000000C722.000000 -353.000000,704.000000 -353.000000,687.000000 -353.000000L409.000000 -353.000000L409.000000 -629.000000C409.000000 -645.000000,409.000000 -666.000000,389.000000 -666.000000C369.000000 -666.000000,369.000000 -648.000000,369.000000 -632.000000L369.000000 -353.000000L90.000000 -353.000000C73.000000 -353.000000,55.000000 -353.000000,55.000000 -333.000000C55.000000 -313.000000,73.000000 -313.000000,90.000000 -313.000000L369.000000 -313.000000L369.000000 -40.000000L90.000000 -40.000000C73.000000 -40.000000,55.000000 -40.000000,55.000000 -20.000000C55.000000 -0.000000,73.000000 -0.000000,90.000000 -0.000000L687.000000 -0.000000C704.000000 -0.000000,722.000000 -0.000000,722.000000 -20.000000C722.000000 -40.000000,704.000000 -40.000000,687.000000 -40.000000L409.000000 -40.000000"></path>
    </g>
  </defs>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,0.823944 10.472168)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmsy10_6"></use>
  </g>
  <g transform="matrix(1.600006,-0.000000,-0.000000,1.600006,13.221924 10.472168)" style="fill: rgb(0.000000%,0.000000%,0.000000%);">
    <use xlink:href="#GLYPHcmr10_49"></use>
  </g>
</svg></span> pixel in the row and column
directions or by using gray value morphology (e.g.,
<a href="gray_erosion_shape.html"><code><span data-if="hdevelop" style="display:inline">gray_erosion_shape</span><span data-if="c" style="display:none">gray_erosion_shape</span><span data-if="cpp" style="display:none">GrayErosionShape</span><span data-if="com" style="display:none">GrayErosionShape</span><span data-if="dotnet" style="display:none">GrayErosionShape</span><span data-if="python" style="display:none">gray_erosion_shape</span></code></a> and <a href="gray_dilation_shape.html"><code><span data-if="hdevelop" style="display:inline">gray_dilation_shape</span><span data-if="c" style="display:none">gray_dilation_shape</span><span data-if="cpp" style="display:none">GrayDilationShape</span><span data-if="com" style="display:none">GrayDilationShape</span><span data-if="dotnet" style="display:none">GrayDilationShape</span><span data-if="python" style="display:none">gray_dilation_shape</span></code></a>), and
then training the synthetically modified images.  A different
possibility to create the variation model from a single image is to
create the model with <a href="#Mode"><i><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></i></a>=<i><span data-if="hdevelop" style="display:inline">'direct'</span><span data-if="c" style="display:none">"direct"</span><span data-if="cpp" style="display:none">"direct"</span><span data-if="com" style="display:none">"direct"</span><span data-if="dotnet" style="display:none">"direct"</span><span data-if="python" style="display:none">"direct"</span></i>.  In this
case, the variation model can only be trained by specifying the
ideal image and the variation image directly with
<a href="prepare_direct_variation_model.html"><code><span data-if="hdevelop" style="display:inline">prepare_direct_variation_model</span><span data-if="c" style="display:none">prepare_direct_variation_model</span><span data-if="cpp" style="display:none">PrepareDirectVariationModel</span><span data-if="com" style="display:none">PrepareDirectVariationModel</span><span data-if="dotnet" style="display:none">PrepareDirectVariationModel</span><span data-if="python" style="display:none">prepare_direct_variation_model</span></code></a>.  Since the variation
typically is large at the edges of the object, edge operators like
<a href="sobel_amp.html"><code><span data-if="hdevelop" style="display:inline">sobel_amp</span><span data-if="c" style="display:none">sobel_amp</span><span data-if="cpp" style="display:none">SobelAmp</span><span data-if="com" style="display:none">SobelAmp</span><span data-if="dotnet" style="display:none">SobelAmp</span><span data-if="python" style="display:none">sobel_amp</span></code></a>, <a href="edges_image.html"><code><span data-if="hdevelop" style="display:inline">edges_image</span><span data-if="c" style="display:none">edges_image</span><span data-if="cpp" style="display:none">EdgesImage</span><span data-if="com" style="display:none">EdgesImage</span><span data-if="dotnet" style="display:none">EdgesImage</span><span data-if="python" style="display:none">edges_image</span></code></a>, or <a href="gray_range_rect.html"><code><span data-if="hdevelop" style="display:inline">gray_range_rect</span><span data-if="c" style="display:none">gray_range_rect</span><span data-if="cpp" style="display:none">GrayRangeRect</span><span data-if="com" style="display:none">GrayRangeRect</span><span data-if="dotnet" style="display:none">GrayRangeRect</span><span data-if="python" style="display:none">gray_range_rect</span></code></a>
should be used to create the variation image.</p>
<h2 id="sec_execution">运行信息</h2>
<ul>
  <li>多线程类型:可重入(与非独占操作符并行运行)。</li>
<li>多线程作用域:全局(可以从任何线程调用)。</li>
  <li>未经并行化处理。</li>
</ul>
<p>This operator returns a handle. Note that the state of an instance of this handle type may be changed by specific operators even though the handle is used as an input parameter by those operators.</p>
<h2 id="sec_parameters">参数表</h2>
  <div class="par">
<div class="parhead">
<span id="Width" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Width</span><span data-if="c" style="display:none">Width</span><span data-if="cpp" style="display:none">Width</span><span data-if="com" style="display:none">Width</span><span data-if="dotnet" style="display:none">width</span><span data-if="python" style="display:none">width</span></code></b> (input_control)  </span><span>extent.x <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Width of the images to be compared.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>640</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>160, 192, 320, 384, 640, 768</p>
</div>
  <div class="par">
<div class="parhead">
<span id="Height" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Height</span><span data-if="c" style="display:none">Height</span><span data-if="cpp" style="display:none">Height</span><span data-if="com" style="display:none">Height</span><span data-if="dotnet" style="display:none">height</span><span data-if="python" style="display:none">height</span></code></b> (input_control)  </span><span>extent.y <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">int</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (integer)</span><span data-if="dotnet" style="display:none"> (<i>int</i> / </span><span data-if="dotnet" style="display:none">long)</span><span data-if="cpp" style="display:none"> (<i>Hlong</i>)</span><span data-if="c" style="display:none"> (<i>Hlong</i>)</span></span>
</div>
<p class="pardesc">Height of the images to be compared.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>480</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span>120, 144, 240, 288, 480, 576</p>
</div>
  <div class="par">
<div class="parhead">
<span id="Type" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Type</span><span data-if="c" style="display:none">Type</span><span data-if="cpp" style="display:none">Type</span><span data-if="com" style="display:none">Type</span><span data-if="dotnet" style="display:none">type</span><span data-if="python" style="display:none">type</span></code></b> (input_control)  </span><span>string <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">str</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (string)</span><span data-if="dotnet" style="display:none"> (<i>string</i>)</span><span data-if="cpp" style="display:none"> (<i>HString</i>)</span><span data-if="c" style="display:none"> (<i>char*</i>)</span></span>
</div>
<p class="pardesc">Type of the images to be compared.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>
    <span data-if="hdevelop" style="display:inline">'byte'</span>
    <span data-if="c" style="display:none">"byte"</span>
    <span data-if="cpp" style="display:none">"byte"</span>
    <span data-if="com" style="display:none">"byte"</span>
    <span data-if="dotnet" style="display:none">"byte"</span>
    <span data-if="python" style="display:none">"byte"</span>
</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span><span data-if="hdevelop" style="display:inline">'byte'</span><span data-if="c" style="display:none">"byte"</span><span data-if="cpp" style="display:none">"byte"</span><span data-if="com" style="display:none">"byte"</span><span data-if="dotnet" style="display:none">"byte"</span><span data-if="python" style="display:none">"byte"</span>, <span data-if="hdevelop" style="display:inline">'int2'</span><span data-if="c" style="display:none">"int2"</span><span data-if="cpp" style="display:none">"int2"</span><span data-if="com" style="display:none">"int2"</span><span data-if="dotnet" style="display:none">"int2"</span><span data-if="python" style="display:none">"int2"</span>, <span data-if="hdevelop" style="display:inline">'uint2'</span><span data-if="c" style="display:none">"uint2"</span><span data-if="cpp" style="display:none">"uint2"</span><span data-if="com" style="display:none">"uint2"</span><span data-if="dotnet" style="display:none">"uint2"</span><span data-if="python" style="display:none">"uint2"</span></p>
</div>
  <div class="par">
<div class="parhead">
<span id="Mode" class="parname"><b><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></b> (input_control)  </span><span>string <code>→</code> <span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">str</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (string)</span><span data-if="dotnet" style="display:none"> (<i>string</i>)</span><span data-if="cpp" style="display:none"> (<i>HString</i>)</span><span data-if="c" style="display:none"> (<i>char*</i>)</span></span>
</div>
<p class="pardesc">Method used for computing the variation model.</p>
<p class="pardesc"><span class="parcat">Default:
      </span>
    <span data-if="hdevelop" style="display:inline">'standard'</span>
    <span data-if="c" style="display:none">"standard"</span>
    <span data-if="cpp" style="display:none">"standard"</span>
    <span data-if="com" style="display:none">"standard"</span>
    <span data-if="dotnet" style="display:none">"standard"</span>
    <span data-if="python" style="display:none">"standard"</span>
</p>
<p class="pardesc"><span class="parcat">Suggested values:
      </span><span data-if="hdevelop" style="display:inline">'standard'</span><span data-if="c" style="display:none">"standard"</span><span data-if="cpp" style="display:none">"standard"</span><span data-if="com" style="display:none">"standard"</span><span data-if="dotnet" style="display:none">"standard"</span><span data-if="python" style="display:none">"standard"</span>, <span data-if="hdevelop" style="display:inline">'robust'</span><span data-if="c" style="display:none">"robust"</span><span data-if="cpp" style="display:none">"robust"</span><span data-if="com" style="display:none">"robust"</span><span data-if="dotnet" style="display:none">"robust"</span><span data-if="python" style="display:none">"robust"</span>, <span data-if="hdevelop" style="display:inline">'direct'</span><span data-if="c" style="display:none">"direct"</span><span data-if="cpp" style="display:none">"direct"</span><span data-if="com" style="display:none">"direct"</span><span data-if="dotnet" style="display:none">"direct"</span><span data-if="python" style="display:none">"direct"</span></p>
</div>
  <div class="par">
<div class="parhead">
<span id="ModelID" class="parname"><b><code><span data-if="hdevelop" style="display:inline">ModelID</span><span data-if="c" style="display:none">ModelID</span><span data-if="cpp" style="display:none">ModelID</span><span data-if="com" style="display:none">ModelID</span><span data-if="dotnet" style="display:none">modelID</span><span data-if="python" style="display:none">model_id</span></code></b> (output_control)  </span><span>variation_model <code>→</code> <span data-if="dotnet" style="display:none"><a href="HVariationModel.html">HVariationModel</a>, </span><span data-if="dotnet" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="python" style="display:none">HHandle</span><span data-if="cpp" style="display:none"><a href="HTuple.html">HTuple</a></span><span data-if="c" style="display:none">Htuple</span><span data-if="hdevelop" style="display:inline"> (handle)</span><span data-if="dotnet" style="display:none"> (<i>IntPtr</i>)</span><span data-if="cpp" style="display:none"> (<i>HHandle</i>)</span><span data-if="c" style="display:none"> (<i>handle</i>)</span></span>
</div>
<p class="pardesc">ID of the variation model.</p>
</div>
<h2 id="sec_complexity">Complexity</h2>
<p>A variation model created with <code><span data-if="hdevelop" style="display:inline">create_variation_model</span><span data-if="c" style="display:none">create_variation_model</span><span data-if="cpp" style="display:none">CreateVariationModel</span><span data-if="com" style="display:none">CreateVariationModel</span><span data-if="dotnet" style="display:none">CreateVariationModel</span><span data-if="python" style="display:none">create_variation_model</span></code>
requires 12*<a href="#Width"><i><code><span data-if="hdevelop" style="display:inline">Width</span><span data-if="c" style="display:none">Width</span><span data-if="cpp" style="display:none">Width</span><span data-if="com" style="display:none">Width</span><span data-if="dotnet" style="display:none">width</span><span data-if="python" style="display:none">width</span></code></i></a>*<a href="#Height"><i><code><span data-if="hdevelop" style="display:inline">Height</span><span data-if="c" style="display:none">Height</span><span data-if="cpp" style="display:none">Height</span><span data-if="com" style="display:none">Height</span><span data-if="dotnet" style="display:none">height</span><span data-if="python" style="display:none">height</span></code></i></a> bytes of memory for
<a href="#Mode"><i><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></i></a> = <i><span data-if="hdevelop" style="display:inline">'standard'</span><span data-if="c" style="display:none">"standard"</span><span data-if="cpp" style="display:none">"standard"</span><span data-if="com" style="display:none">"standard"</span><span data-if="dotnet" style="display:none">"standard"</span><span data-if="python" style="display:none">"standard"</span></i> and <a href="#Mode"><i><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></i></a> =
<i><span data-if="hdevelop" style="display:inline">'robust'</span><span data-if="c" style="display:none">"robust"</span><span data-if="cpp" style="display:none">"robust"</span><span data-if="com" style="display:none">"robust"</span><span data-if="dotnet" style="display:none">"robust"</span><span data-if="python" style="display:none">"robust"</span></i> for <a href="#Type"><i><code><span data-if="hdevelop" style="display:inline">Type</span><span data-if="c" style="display:none">Type</span><span data-if="cpp" style="display:none">Type</span><span data-if="com" style="display:none">Type</span><span data-if="dotnet" style="display:none">type</span><span data-if="python" style="display:none">type</span></code></i></a> = <i><span data-if="hdevelop" style="display:inline">'byte'</span><span data-if="c" style="display:none">"byte"</span><span data-if="cpp" style="display:none">"byte"</span><span data-if="com" style="display:none">"byte"</span><span data-if="dotnet" style="display:none">"byte"</span><span data-if="python" style="display:none">"byte"</span></i>.  For
<a href="#Type"><i><code><span data-if="hdevelop" style="display:inline">Type</span><span data-if="c" style="display:none">Type</span><span data-if="cpp" style="display:none">Type</span><span data-if="com" style="display:none">Type</span><span data-if="dotnet" style="display:none">type</span><span data-if="python" style="display:none">type</span></code></i></a> = <i><span data-if="hdevelop" style="display:inline">'uint2'</span><span data-if="c" style="display:none">"uint2"</span><span data-if="cpp" style="display:none">"uint2"</span><span data-if="com" style="display:none">"uint2"</span><span data-if="dotnet" style="display:none">"uint2"</span><span data-if="python" style="display:none">"uint2"</span></i> and <a href="#Type"><i><code><span data-if="hdevelop" style="display:inline">Type</span><span data-if="c" style="display:none">Type</span><span data-if="cpp" style="display:none">Type</span><span data-if="com" style="display:none">Type</span><span data-if="dotnet" style="display:none">type</span><span data-if="python" style="display:none">type</span></code></i></a> =
<i><span data-if="hdevelop" style="display:inline">'int2'</span><span data-if="c" style="display:none">"int2"</span><span data-if="cpp" style="display:none">"int2"</span><span data-if="com" style="display:none">"int2"</span><span data-if="dotnet" style="display:none">"int2"</span><span data-if="python" style="display:none">"int2"</span></i>, 14*<a href="#Width"><i><code><span data-if="hdevelop" style="display:inline">Width</span><span data-if="c" style="display:none">Width</span><span data-if="cpp" style="display:none">Width</span><span data-if="com" style="display:none">Width</span><span data-if="dotnet" style="display:none">width</span><span data-if="python" style="display:none">width</span></code></i></a>*<a href="#Height"><i><code><span data-if="hdevelop" style="display:inline">Height</span><span data-if="c" style="display:none">Height</span><span data-if="cpp" style="display:none">Height</span><span data-if="com" style="display:none">Height</span><span data-if="dotnet" style="display:none">height</span><span data-if="python" style="display:none">height</span></code></i></a> are required.
For <a href="#Mode"><i><code><span data-if="hdevelop" style="display:inline">Mode</span><span data-if="c" style="display:none">Mode</span><span data-if="cpp" style="display:none">Mode</span><span data-if="com" style="display:none">Mode</span><span data-if="dotnet" style="display:none">mode</span><span data-if="python" style="display:none">mode</span></code></i></a> = <i><span data-if="hdevelop" style="display:inline">'direct'</span><span data-if="c" style="display:none">"direct"</span><span data-if="cpp" style="display:none">"direct"</span><span data-if="com" style="display:none">"direct"</span><span data-if="dotnet" style="display:none">"direct"</span><span data-if="python" style="display:none">"direct"</span></i> and after the training data
has been cleared with <a href="clear_train_data_variation_model.html"><code><span data-if="hdevelop" style="display:inline">clear_train_data_variation_model</span><span data-if="c" style="display:none">clear_train_data_variation_model</span><span data-if="cpp" style="display:none">ClearTrainDataVariationModel</span><span data-if="com" style="display:none">ClearTrainDataVariationModel</span><span data-if="dotnet" style="display:none">ClearTrainDataVariationModel</span><span data-if="python" style="display:none">clear_train_data_variation_model</span></code></a>,
2*<a href="#Width"><i><code><span data-if="hdevelop" style="display:inline">Width</span><span data-if="c" style="display:none">Width</span><span data-if="cpp" style="display:none">Width</span><span data-if="com" style="display:none">Width</span><span data-if="dotnet" style="display:none">width</span><span data-if="python" style="display:none">width</span></code></i></a>*<a href="#Height"><i><code><span data-if="hdevelop" style="display:inline">Height</span><span data-if="c" style="display:none">Height</span><span data-if="cpp" style="display:none">Height</span><span data-if="com" style="display:none">Height</span><span data-if="dotnet" style="display:none">height</span><span data-if="python" style="display:none">height</span></code></i></a> bytes are required for
<a href="#Type"><i><code><span data-if="hdevelop" style="display:inline">Type</span><span data-if="c" style="display:none">Type</span><span data-if="cpp" style="display:none">Type</span><span data-if="com" style="display:none">Type</span><span data-if="dotnet" style="display:none">type</span><span data-if="python" style="display:none">type</span></code></i></a> = <i><span data-if="hdevelop" style="display:inline">'byte'</span><span data-if="c" style="display:none">"byte"</span><span data-if="cpp" style="display:none">"byte"</span><span data-if="com" style="display:none">"byte"</span><span data-if="dotnet" style="display:none">"byte"</span><span data-if="python" style="display:none">"byte"</span></i> and
4*<a href="#Width"><i><code><span data-if="hdevelop" style="display:inline">Width</span><span data-if="c" style="display:none">Width</span><span data-if="cpp" style="display:none">Width</span><span data-if="com" style="display:none">Width</span><span data-if="dotnet" style="display:none">width</span><span data-if="python" style="display:none">width</span></code></i></a>*<a href="#Height"><i><code><span data-if="hdevelop" style="display:inline">Height</span><span data-if="c" style="display:none">Height</span><span data-if="cpp" style="display:none">Height</span><span data-if="com" style="display:none">Height</span><span data-if="dotnet" style="display:none">height</span><span data-if="python" style="display:none">height</span></code></i></a> for the other image types.</p>
<h2 id="sec_result">结果</h2>
<p><code><span data-if="hdevelop" style="display:inline">create_variation_model</span><span data-if="c" style="display:none">create_variation_model</span><span data-if="cpp" style="display:none">CreateVariationModel</span><span data-if="com" style="display:none">CreateVariationModel</span><span data-if="dotnet" style="display:none">CreateVariationModel</span><span data-if="python" style="display:none">create_variation_model</span></code> returns <TT>2</TT> (
      <TT>H_MSG_TRUE</TT>)
     if all parameters are
correct.</p>
<h2 id="sec_successors">可能的后置算子</h2>
<p>
<code><a href="train_variation_model.html"><span data-if="hdevelop" style="display:inline">train_variation_model</span><span data-if="c" style="display:none">train_variation_model</span><span data-if="cpp" style="display:none">TrainVariationModel</span><span data-if="com" style="display:none">TrainVariationModel</span><span data-if="dotnet" style="display:none">TrainVariationModel</span><span data-if="python" style="display:none">train_variation_model</span></a></code>, 
<code><a href="prepare_direct_variation_model.html"><span data-if="hdevelop" style="display:inline">prepare_direct_variation_model</span><span data-if="c" style="display:none">prepare_direct_variation_model</span><span data-if="cpp" style="display:none">PrepareDirectVariationModel</span><span data-if="com" style="display:none">PrepareDirectVariationModel</span><span data-if="dotnet" style="display:none">PrepareDirectVariationModel</span><span data-if="python" style="display:none">prepare_direct_variation_model</span></a></code>
</p>
<h2 id="sec_see">参考其它</h2>
<p>
<code><a href="prepare_variation_model.html"><span data-if="hdevelop" style="display:inline">prepare_variation_model</span><span data-if="c" style="display:none">prepare_variation_model</span><span data-if="cpp" style="display:none">PrepareVariationModel</span><span data-if="com" style="display:none">PrepareVariationModel</span><span data-if="dotnet" style="display:none">PrepareVariationModel</span><span data-if="python" style="display:none">prepare_variation_model</span></a></code>, 
<code><a href="clear_variation_model.html"><span data-if="hdevelop" style="display:inline">clear_variation_model</span><span data-if="c" style="display:none">clear_variation_model</span><span data-if="cpp" style="display:none">ClearVariationModel</span><span data-if="com" style="display:none">ClearVariationModel</span><span data-if="dotnet" style="display:none">ClearVariationModel</span><span data-if="python" style="display:none">clear_variation_model</span></a></code>, 
<code><a href="clear_train_data_variation_model.html"><span data-if="hdevelop" style="display:inline">clear_train_data_variation_model</span><span data-if="c" style="display:none">clear_train_data_variation_model</span><span data-if="cpp" style="display:none">ClearTrainDataVariationModel</span><span data-if="com" style="display:none">ClearTrainDataVariationModel</span><span data-if="dotnet" style="display:none">ClearTrainDataVariationModel</span><span data-if="python" style="display:none">clear_train_data_variation_model</span></a></code>, 
<code><a href="find_generic_shape_model.html"><span data-if="hdevelop" style="display:inline">find_generic_shape_model</span><span data-if="c" style="display:none">find_generic_shape_model</span><span data-if="cpp" style="display:none">FindGenericShapeModel</span><span data-if="com" style="display:none">FindGenericShapeModel</span><span data-if="dotnet" style="display:none">FindGenericShapeModel</span><span data-if="python" style="display:none">find_generic_shape_model</span></a></code>, 
<code><a href="affine_trans_image.html"><span data-if="hdevelop" style="display:inline">affine_trans_image</span><span data-if="c" style="display:none">affine_trans_image</span><span data-if="cpp" style="display:none">AffineTransImage</span><span data-if="com" style="display:none">AffineTransImage</span><span data-if="dotnet" style="display:none">AffineTransImage</span><span data-if="python" style="display:none">affine_trans_image</span></a></code>
</p>
<h2 id="sec_module">模块</h2>
<p>
Matching</p>
<!--OP_REF_FOOTER_START-->
<hr>
<div class="indexlink">
<a href="index_classes.html"><span data-if="dotnet" style="display:none;">类别</span><span data-if="cpp" style="display:none;">类别</span></a><span data-if="dotnet" style="display:none;"> | </span><span data-if="cpp" style="display:none;"> | </span><a href="index_by_name.html">算子列表</a>
</div>
<div class="footer">
<div class="copyright">HALCON算子参考手册 Copyright © 2015-2023 51Halcon</div>
</div>
</div>
</body>
</html>
